﻿<%@ Page Language="C#" EnableEventValidation="false" MasterPageFile="~/Member/UserManage.master"
    AutoEventWireup="true" CodeFile="ExpoList.aspx.cs" Inherits="Member_Expo_ExpoList" %>

<%@ Register Src="../../Control/PageNo.ascx" TagName="PageNo" TagPrefix="uc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContInfo" runat="server">

    <script type="text/javascript">
        function SelectAll()
        {
            // 找到所有的 input 元素
            var ctllist = document.getElementsByTagName("input");
            var objcheckbox= document.getElementById("CheckBox2");     
            for( var i = 0; i< ctllist.length; i++)
            {
                if(ctllist[i].type == "checkbox" && ctllist[i].name.indexOf( "CheckBox1") >=0 )
                {   
                    if(objcheckbox.checked==true)     
                         ctllist[i].checked = true;
                    else
                         ctllist[i].checked = false;
                }
          
             }
         }
    </script>

    <form id="form1" action="">
        <div id="sub_content">
            <div class="pagetitle">
                展会管理</div>
            <div class="tishi">
                <span>提&nbsp;示：</span>·请慎重修改！
            </div>
            <div class="main_Supply_nav">
                <ul id="menu">
                    <li id="menu1" runat="server"><a href="ExpoList.aspx?Verify=1">已发布上网</a></li><li
                        id="menu2" runat="server" class="MenuLi"><a href="ExpoList.aspx?Verify=3">审核未通过</a></li><li
                            id="menu3" runat="server" class="MenuLi"><a href="ExpoList.aspx?Verify=2">审核中</a></li><li
                                id="menu4" runat="server" class="MenuLi"><a href="ExpoList.aspx?Verify=4">过期信息</a></li></ul>
            </div>
            <div class="clr">
            </div>
            <table width="795" border="0" cellpadding="0" cellspacing="0" style="margin-bottom: 5px;">
                <tbody>
                    <tr>
                        <td colspan="2">
                            <asp:TextBox ID="txtKeyword" runat="server" Height="17"></asp:TextBox>
                            <asp:DropDownList ID="dropExpoType" runat="server"></asp:DropDownList>
                            <asp:Button ID="btnSelect" OnClick="btnSelect_Click" runat="server" Text="立即查询" CssClass="i_button"></asp:Button></td>
                    </tr>
                </tbody>
            </table>
            <asp:GridView ID="grdExpo" DataKeyNames="ID" runat="server" AutoGenerateColumns="False" CellPadding="0"
                Font-Overline="False" AllowPaging="false" CssClass="table_main">
                <Columns>
                    <asp:TemplateField HeaderText="选项">
                        <ItemTemplate>
                            <asp:CheckBox ID="CheckBox1" runat="server" />
                        </ItemTemplate>
                        <HeaderStyle CssClass="th20 tou" />
                        <ItemStyle CssClass="nolet" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="信息标题">
                        <ItemTemplate>
                            <%# Eval("Title") %>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="所属类别">
                        <ItemTemplate>
                            <a style="text-decoration: none" href='ExpoList.aspx?TypeID=<%# DataBinder.Eval(Container.DataItem,"TypeID") %>'>
                                <%# DataBinder.Eval(Container.DataItem, "Type") %>
                            </a>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText=" 开始日期">
                        <ItemTemplate>
                            <%# GetShortDate(DataBinder.Eval(Container.DataItem, "StartDate").ToString())%>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="结束日期">
                        <ItemTemplate>
                            <%# GetShortDate(DataBinder.Eval(Container.DataItem, "EndDate").ToString())%>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField>
                        <HeaderTemplate>
                            修改
                        </HeaderTemplate>
                        <ItemTemplate>
                            <a href='ExpoEdit.aspx?id=<%# DataBinder.Eval(Container.DataItem,"ID") %>'>修改</a>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
            </asp:GridView>
            <div class="paging">
                <p><uc1:PageNo ID="PageNo1" runat="server" /></p>
                    <asp:Label ID="lblMessage" runat="server"></asp:Label>
                <input id="CheckBox2" name="CheckBox2" onclick="SelectAll();" type="checkbox" /> 全选
                <asp:Button ID="btnDelete" runat="server" OnClick="btnDelete_Click" Text="批量删除" CssClass="i_button" />
                
            </div>
        </div>
    </form>
</asp:Content>
